package org.fastsyncer.common.constant;

import java.util.HashMap;

/**
 * <p>目前支持：</p>
 * <ul>
 * <li>Database连接器</li>
 * <li>Webservice连接器</li>
 * <li>Ladp连接器</li>
 * </ul>
 * @ClassName: ConnectorConstant 
 * @Description: 连接器类型常量类型
 * @author: YangPei
 * @date: 2017年8月11日 上午11:05:39
 */
public class ConnectorConstant {

	/**
	 * 数据库连接器
	 */
	public static final String DB_CONNECTOR = "org.fastsyncer.connector.database.DatabaseConnector";

	/**
	 * Webservice连接器
	 */
	public static final String WS_CONNECTOR = "org.fastsyncer.connector.ws.WebServiceConnector";

	/**
	 * Ladp连接器
	 */
	public static final String LDAP_CONNECTOR = "org.fastsyncer.connector.ldap.LdapConnector";
	
	/**
	 * 插入
	 */
	public static final String OPERTION_INSERT = "insert";

	/**
	 * 更新
	 */
	public static final String OPERTION_UPDATE = "update";

	/**
	 * 删除
	 */
	public static final String OPERTION_DELETE = "delete";

	/**
	 * 查询
	 */
	public static final String OPERTION_QUERY = "query";
	
	/**
	 * 条件查询and
	 */
	public static final String OPERTION_QUERY_AND = "and";
	
	/**
	 * 条件查询or
	 */
	public static final String OPERTION_QUERY_OR = "or";
	
	/**
	 * 查询表达式
	 */
	public static final HashMap<String, String> OPERS = new HashMap<String, String>();
	
	static {
		OPERS.put("equal", "=");
		OPERS.put("notEqual", "!=");
		OPERS.put("gt", ">");
		OPERS.put("lt", "<");
		OPERS.put("gtAndEqual", ">=");
		OPERS.put("ltAndEqual", "<=");
	}
	
}
